package org.javaboy.csrf01.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

@Controller
public class AccountController {

    @PostMapping("/transfer")
    @ResponseBody
    public void transferMoney(String from, String to, Double money) {
        System.out.println("from = " + from);
        System.out.println("to = " + to);
        System.out.println("money = " + money);
    }

    @GetMapping("/02")
    public String hello02() {
        return "02";
    }
}
